package com.baizhi.utils;

import java.util.ArrayList;
import java.util.List;
import java.util.Random;

/**
 * @author liukaixuan
 */
public class ImageUtils {


    private static List<String> photos;

    static {
        photos = new ArrayList<>();
        photos.add("https://z3.ax1x.com/2021/07/19/W8HFW4.jpg");
        photos.add("https://z3.ax1x.com/2021/07/19/W8HiYF.jpg");
    }

    /**
     * 随机选择list中一个头像路径
     * @return
     */
    public static String getPhoto(){
        int i = new Random().nextInt(photos.size());
        return photos.get(i);
    }

}
